package cn.slipi.core.plugin;

import org.springframework.web.server.ServerWebExchange;
import reactor.core.publisher.Mono;

/**
 * 插件抽象类
 */
public interface IPlugin {
    int getCode();

    String getName();

    String getPluginPhase();

    default boolean skip(ServerWebExchange exchange) {
        return false;
    }

    Mono<Void> execute(ServerWebExchange exchange, IPluginChain chain);
}
